import axios from 'axios'
const instance = axios.create({
  baseURL: 'http://localhost:3000', //域名
  timeout: 5000, // 超时时间
})

// 创建新歌单
export const creatlistAPI = (data) => instance.post('/playlist/create', data)
//获取用户歌单
export const userlistAPI = (params) =>
  instance.get('/user/playlist', { params: params })
//获取精品歌单
export const goodlistAPI = (params) =>
  instance.get('/top/playlist/highquality', { params: params })
//获取登录状态
export const loginstatusAPI = (params) =>
  instance.get('/login/status', { params: params })
//获取用户信息
export const getusermsgAPI = (params) =>
  instance.get('/user/subcount', { params: params })
//歌单(网友精选碟)
export const playlistAPI = (params) =>
  instance.get('/top/playlist', { params: params })
